home *** CD-ROM | disk | FTP | other *** search
/ IRIX Base Documentation 2002 November / SGI IRIX Base Documentation 2002 November.iso / usr / share / catman / p_man / cat3 / ifl / iflClassList.z / iflClassList
Encoding:
Text File  |  2002-10-03  |  5.6 KB  |  133 lines

  1.  
  2.  
  3.  
  4. iiiiffffllllCCCCllllaaaassssssssLLLLiiiisssstttt((((3333))))   IIIImmmmaaaaggggeeee FFFFoooorrrrmmmmaaaatttt LLLLiiiibbbbrrrraaaarrrryyyy CCCC++++++++ RRRReeeeffffeeeerrrreeeennnncccceeee MMMMaaaannnnuuuuaaaallll    iiiiffffllllCCCCllllaaaassssssssLLLLiiiisssstttt((((3333))))
  5.  
  6.  
  7.  
  8. NNNNAAAAMMMMEEEE
  9.      iiiiffffllllCCCCllllaaaassssssssLLLLiiiisssstttt - class inheritance chain
  10.  
  11. IIIINNNNHHHHEEEERRRRIIIITTTTSSSS FFFFRRRROOOOMMMM
  12.      This is a base class
  13.  
  14. HHHHEEEEAAAADDDDEEEERRRR FFFFIIIILLLLEEEE
  15.      #include <ifl/iflClassList.h>
  16.  
  17. CCCCLLLLAAAASSSSSSSS DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN
  18.      iflClassList is used to statically create a class inheritance chain; it's
  19.      not setup to deal with multiple inheritance, just the "primary" base
  20.      class.
  21.  
  22.    UUUUssssaaaaggggeeee
  23.      Put the iiiiffffllllCCCCllllaaaassssssssLLLLiiiissssttttDDDDeeeeccccllllaaaarrrreeee macro in the public section of a class
  24.      declaration derived from a base class and the iiiiffffllllCCCCllllaaaassssssssLLLLiiiissssttttIIIImmmmpppplllleeeemmmmeeeennnnttttBBBBaaaasssseeee
  25.      or iiiiffffllllCCCCllllaaaassssssssLLLLiiiissssttttIIIImmmmpppplllleeeemmmmeeeennnnttttDDDDeeeerrrriiiivvvveeeedddd macro in the implementation file. These
  26.      macros will declare and implement the methods described below, thus
  27.      allowing the class hierarchy to be interrogated.
  28.  
  29.      Refer to <il/ilLink.h> and <il/ilImage.h> for examples of the use of
  30.      these macros.
  31.  
  32.    PPPPuuuubbbblllliiiicccc mmmmeeeetttthhhhooooddddssss aaaaddddddddeeeedddd
  33.      The folling public methods are added to the invoking class by the
  34.      iflClassListImplementXXX macros:
  35.  
  36.      ggggeeeettttCCCCllllaaaassssssssNNNNaaaammmmeeee(((())))
  37.  
  38.           virtual char* getClassName(int parentIdx=0)
  39.  
  40.  
  41.           This method specifies the name of the class for this object
  42.           instantiantion (or of the nearest ancestor class that registers
  43.           itself using this macro.) The optional _p_a_r_e_n_t_I_d_x argument allows the
  44.           name of one of the parent classes to be returned, the values
  45.           specifies how may levels of the class hierarchy to traverse.
  46.  
  47.      ggggeeeettttCCCCllllaaaassssssssIIIIdddd(((())))
  48.  
  49.            virtual iflClassId getClassId()
  50.  
  51.  
  52.           This method returns the class ID for this object instantiantion.
  53.  
  54.      ddddeeeerrrriiiivvvveeeessssFFFFrrrroooommmm(((())))
  55.  
  56.           virtual int derivesFrom(iflClassId classID)
  57.  
  58.  
  59.  
  60.  
  61.  
  62.  
  63.                                                                         PPPPaaaaggggeeee 1111
  64.  
  65.  
  66.  
  67.  
  68.  
  69.  
  70. iiiiffffllllCCCCllllaaaassssssssLLLLiiiisssstttt((((3333))))   IIIImmmmaaaaggggeeee FFFFoooorrrrmmmmaaaatttt LLLLiiiibbbbrrrraaaarrrryyyy CCCC++++++++ RRRReeeeffffeeeerrrreeeennnncccceeee MMMMaaaannnnuuuuaaaallll    iiiiffffllllCCCCllllaaaassssssssLLLLiiiisssstttt((((3333))))
  71.  
  72.  
  73.  
  74.           This method returns TRUE if this object instantiantion derives from
  75.           the class indicated by classID.  This classID is formed using the
  76.           iflClassID macro defined in ilTypes.h; e.g. "iflClassID(ilImage)"
  77.  
  78.    PPPPrrrrooootttteeeecccctttteeeedddd mmmmeeeetttthhhhooooddddssss aaaaddddddddeeeedddd
  79.      The following protected method is added to the invoking class by the
  80.      iflClassListImplementXXX macros:
  81.  
  82.      ggggeeeettttDDDDeeeeffffaaaauuuullllttttDDDDeeeessssccccrrrriiiippppttttiiiioooonnnn(((())))
  83.  
  84.           virtual char* getDefaultDescription()
  85.  
  86.  
  87.           This method returns the default description for this object
  88.           instantiantion. This is the string supplied in the
  89.           iflClassListImplement* macros.
  90.  
  91. CCCCLLLLAAAASSSSSSSS MMMMEEEEMMMMBBBBEEEERRRR FFFFUUUUNNNNCCCCTTTTIIIIOOOONNNN SSSSUUUUMMMMMMMMAAAARRRRYYYY
  92.      CCCCllllaaaassssssss llllooooooookkkkuuuupppp mmmmeeeetttthhhhooooddddssss
  93.  
  94.           int find(iflClassId classID)
  95.           char* find(int parentIdx)
  96.  
  97.  
  98. FFFFUUUUNNNNCCCCTTTTIIIIOOOONNNN DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNNSSSS
  99.      ffffiiiinnnndddd(((())))
  100.  
  101.           char* find(int parentIdx)
  102.           int find(iflClassId classID)
  103.  
  104.  
  105.           This first version returns the name of the class, _p_a_r_e_n_t_I_d_x levels
  106.           up in the class list.  The second versions returns TRUE if _c_l_a_s_s_I_D
  107.           is found in the class list.
  108.  
  109.  
  110.  
  111.  
  112.  
  113.  
  114.  
  115.  
  116.  
  117.  
  118.  
  119.  
  120.  
  121.  
  122.  
  123.  
  124.  
  125.  
  126.  
  127.  
  128.  
  129.                                                                         PPPPaaaaggggeeee 2222
  130.  
  131.  
  132.  
  133.